<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:Converters="clr-namespace:Cradiator.Converters;assembly=Cradiator" >

    <DataTemplate x:Key="SkinTemplate">
        <Border BorderBrush="Black" BorderThickness="0.5">
            <StackPanel Orientation="Vertical">
                <TextBlock Padding="1" TextAlignment="Center" FontFamily="Tahoma">
                
                <Image Margin="0,0,0,-3" Stretch="Fill"
                       Source="{Binding Path=CurrentMessage, Converter={Converters:ImagePathConverter}}" 
                       Width="{Binding Path=CurrentMessage, Converter={Converters:ImageSizeConverter}}" 
                       Height="{Binding Path=CurrentMessage, Converter={Converters:ImageSizeConverter}}"  />
               
                <TextBlock Text="{Binding Path=Name}" />               
                <TextBlock FontSize="9" Foreground="DarkRed" 
                           Text="{Binding Path=CurrentMessage, Converter={Converters:OneBreakerConverter}}" />
                
                <TextBlock.Background>
                    <LinearGradientBrush EndPoint="0,1">
                        <GradientStop Offset="0" 
                                      Color="{Binding Path=CurrentState, Converter={Converters:StateToGradientConverter}}"/>
                        <GradientStop Offset="0.5" 
                                      Color="{Binding Path=CurrentState, Converter={Converters:StateToColorConverter}}"/>
                    </LinearGradientBrush>
                </TextBlock.Background>                
                
                </TextBlock>
                <TextBlock Visibility="{Binding ServerNameVisible}" Text="{Binding ServerName}" TextAlignment="Center" Foreground="WhiteSmoke">
                    <TextBlock.Background>
                        <LinearGradientBrush EndPoint="0,2" >
                            <GradientStop Offset="0" Color="LightBlue" />
                            <GradientStop Offset="0.5" Color="DarkBlue" />
                        </LinearGradientBrush >
                    </TextBlock.Background>
                </TextBlock>
            </StackPanel>
        </Border>
    </DataTemplate>

    <Style x:Key="SkinStyle" TargetType="{x:Type ItemsControl}">
        <Setter Property="ItemTemplate" Value="{StaticResource SkinTemplate}" />
    </Style>

</ResourceDictionary>
